package com.atjava.nebula.weixin.ssl;

import com.atjava.nebula.core.exception.baseExp.BusinessException;
import com.atjava.nebula.web.ssl.HttpsClient;

public class WeixinSendInfoCaller {

	private static final String SEND_INFO_URL = "https://qyapi.weixin.qq.com/cgi-bin/message/send?access_token=";
	
	public String sendInfo(String jsonTypeOfText,String access_token) throws BusinessException {
		
		HttpsClient client = new HttpsClient();
		try {
			String resultJson = client.post(SEND_INFO_URL+access_token,jsonTypeOfText);
			System.out.println(resultJson);
			return resultJson;
		} catch (Exception e) {
			throw new BusinessException(e,"发送信息失败！");
		}
		
	}
}
